package com.ktkj.init.dto;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

@ApiModel
@Data
public class SysJobForm {

    @NotBlank(message = "任务名称不能为空！")
    @ApiModelProperty(value = "任务名称", example = "测试方法1", required = true)
    private String jobName;

    @NotBlank(message = "调用目标字符串不能为空！")
    @ApiModelProperty(value = "调用目标字符串", example = "testTask.method1", required = true)
    private String invokeTarget;

    @NotBlank(message = "cron执行表达式不能为空！")
    @ApiModelProperty(value = "cron执行表达式", example = "0/10 * * * * ?", required = true)
    private String cronExpression;

    @NotNull(message = "状态不能为空！")
    @ApiModelProperty(value = "状态（0：正常 1：暂停）", example = "1", required = true)
    private Integer status;

    @ApiModelProperty(value = "id(修改时必须输入)", example = "1")
    private Long id;

}
